using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._GeoAnalyticsServerTools._SummarizeData
{
    /// <summary>
    /// <para>Summarize Center And Dispersion</para>
    /// <para>Finds central features and directional distributions and calculates mean and median locations from the input.</para>
    /// <para>查找中心要素和方向分布，并根据输入计算平均值和中位数位置。</para>
    /// </summary>    
    [DisplayName("Summarize Center And Dispersion")]
    public class SummarizeCenterAndDispersion : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public SummarizeCenterAndDispersion()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_input_layer">
        /// <para>Input Layer</para>
        /// <para>The point, line, or polygon layer to be summarized.</para>
        /// <para>要汇总的点、线或面图层。</para>
        /// </param>
        /// <param name="_output_name">
        /// <para>Output Name</para>
        /// <para>The name of the output feature service.</para>
        /// <para>输出要素服务的名称。</para>
        /// </param>
        /// <param name="_generate_types">
        /// <para>Generate Types</para>
        /// <para><xdoc>
        ///   <para>Specifies the summary types to be generated. You can use one or more summary types. A unique layer will be created for each summary type selected.</para>
        ///   <bulletList>
        ///     <bullet_item>Central Feature—A layer will be created that contains a copy of the most central feature from the input layer.</bullet_item><para/>
        ///     <bullet_item>Mean Center—A point layer will be created that represents the mean center of the input layer.</bullet_item><para/>
        ///     <bullet_item>Median Center—A point layer will be created that represents the median center of the input layer.</bullet_item><para/>
        ///     <bullet_item>Ellipse—A polygon layer will be created that represents the directional ellipse of the input layer.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定要生成的摘要类型。可以使用一种或多种摘要类型。将为所选的每个摘要类型创建一个唯一的图层。</para>
        ///   <bulletList>
        ///     <bullet_item>中心要素 - 将创建一个图层，其中包含输入图层中最中心要素的副本。</bullet_item><para/>
        ///     <bullet_item>平均中心—将创建一个点图层，该点图层表示输入图层的平均中心。</bullet_item><para/>
        ///     <bullet_item>中位中心—将创建一个点图层，该图层表示输入图层的中位中心。</bullet_item><para/>
        ///     <bullet_item>椭圆—将创建一个面图层，该图层表示输入图层的方向椭圆。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// </param>
        public SummarizeCenterAndDispersion(object _input_layer, object _output_name, List<object> _generate_types)
        {
            this._input_layer = _input_layer;
            this._output_name = _output_name;
            this._generate_types = _generate_types;
        }
        public override string ToolboxName => "GeoAnalytics Server Tools";

        public override string ToolName => "Summarize Center And Dispersion";

        public override string CallName => "geoanalytics.SummarizeCenterAndDispersion";

        public override List<string> AcceptEnvironments => ["extent", "outputCoordinateSystem", "workspace"];

        public override object[] ParameterInfo => [_input_layer, _output_name, _generate_types, _ellipse_size.GetGPValue(), _weight_field, _group_by_field, _out_central_feature_layer, _out_mean_center_layer, _out_median_center_layer, _out_ellipse_layer, _data_store.GetGPValue()];

        /// <summary>
        /// <para>Input Layer</para>
        /// <para>The point, line, or polygon layer to be summarized.</para>
        /// <para>要汇总的点、线或面图层。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Layer")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _input_layer { get; set; }


        /// <summary>
        /// <para>Output Name</para>
        /// <para>The name of the output feature service.</para>
        /// <para>输出要素服务的名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Name")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _output_name { get; set; }


        /// <summary>
        /// <para>Generate Types</para>
        /// <para><xdoc>
        ///   <para>Specifies the summary types to be generated. You can use one or more summary types. A unique layer will be created for each summary type selected.</para>
        ///   <bulletList>
        ///     <bullet_item>Central Feature—A layer will be created that contains a copy of the most central feature from the input layer.</bullet_item><para/>
        ///     <bullet_item>Mean Center—A point layer will be created that represents the mean center of the input layer.</bullet_item><para/>
        ///     <bullet_item>Median Center—A point layer will be created that represents the median center of the input layer.</bullet_item><para/>
        ///     <bullet_item>Ellipse—A polygon layer will be created that represents the directional ellipse of the input layer.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定要生成的摘要类型。可以使用一种或多种摘要类型。将为所选的每个摘要类型创建一个唯一的图层。</para>
        ///   <bulletList>
        ///     <bullet_item>中心要素 - 将创建一个图层，其中包含输入图层中最中心要素的副本。</bullet_item><para/>
        ///     <bullet_item>平均中心—将创建一个点图层，该点图层表示输入图层的平均中心。</bullet_item><para/>
        ///     <bullet_item>中位中心—将创建一个点图层，该图层表示输入图层的中位中心。</bullet_item><para/>
        ///     <bullet_item>椭圆—将创建一个面图层，该图层表示输入图层的方向椭圆。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Generate Types")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public List<object> _generate_types { get; set; }


        /// <summary>
        /// <para>Ellipse Size</para>
        /// <para><xdoc>
        ///   <para>Specifies the size of output ellipses in standard deviations.</para>
        ///   <bulletList>
        ///     <bullet_item>One standard deviation—Output ellipses will cover one standard deviation of the input features. This is the default.</bullet_item><para/>
        ///     <bullet_item>Two standard deviations—Output ellipses will cover two standard deviations of the input features.</bullet_item><para/>
        ///     <bullet_item>Three standard deviations—Output ellipses will cover three standard deviations of the input features.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定以标准差为单位的输出椭圆的大小。</para>
        ///   <bulletList>
        ///     <bullet_item>一个标准差—输出椭圆将覆盖输入要素的一个标准差。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>两个标准差—输出椭圆将涵盖输入要素的两个标准差。</bullet_item><para/>
        ///     <bullet_item>三个标准差—输出椭圆将涵盖输入要素的三个标准差。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Ellipse Size")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _ellipse_size_value _ellipse_size { get; set; } = _ellipse_size_value._1_STANDARD_DEVIATION;

        public enum _ellipse_size_value
        {
            /// <summary>
            /// <para>One standard deviation</para>
            /// <para>One standard deviation—Output ellipses will cover one standard deviation of the input features. This is the default.</para>
            /// <para>一个标准差—输出椭圆将覆盖输入要素的一个标准差。这是默认设置。</para>
            /// </summary>
            [Description("One standard deviation")]
            [GPEnumValue("1_STANDARD_DEVIATION")]
            _1_STANDARD_DEVIATION,

            /// <summary>
            /// <para>Two standard deviations</para>
            /// <para>Two standard deviations—Output ellipses will cover two standard deviations of the input features.</para>
            /// <para>两个标准差—输出椭圆将涵盖输入要素的两个标准差。</para>
            /// </summary>
            [Description("Two standard deviations")]
            [GPEnumValue("2_STANDARD_DEVIATIONS")]
            _2_STANDARD_DEVIATIONS,

            /// <summary>
            /// <para>Three standard deviations</para>
            /// <para>Three standard deviations—Output ellipses will cover three standard deviations of the input features.</para>
            /// <para>三个标准差—输出椭圆将涵盖输入要素的三个标准差。</para>
            /// </summary>
            [Description("Three standard deviations")]
            [GPEnumValue("3_STANDARD_DEVIATIONS")]
            _3_STANDARD_DEVIATIONS,

        }

        /// <summary>
        /// <para>Weight Field</para>
        /// <para>A numeric field used to weight locations according to their relative importance. This applies to all summary types.</para>
        /// <para>一个数值字段，用于根据位置的相对重要性对位置进行加权。这适用于所有摘要类型。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Weight Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _weight_field { get; set; } = null;


        /// <summary>
        /// <para>Group By Field</para>
        /// <para>The field used to group similar features. This applies to all summary types. For example, if you choose a field named PlantType that contains values of tree, bush, and grass, all of the features with the value tree will be analyzed for their own center or dispersion. This example will result in three features, one for each group of tree, bush, and grass.</para>
        /// <para>用于对相似要素进行分组的字段。这适用于所有摘要类型。例如，如果选择名为 PlantType 的字段，其中包含 tree、bush 和 grass 的值，则将分析具有值树的所有要素的中心或离散。此示例将生成三个要素，每组树、灌木和草各一个要素。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Group By Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _group_by_field { get; set; } = null;


        /// <summary>
        /// <para>Central Feature Layer</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Central Feature Layer")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_central_feature_layer { get; set; }


        /// <summary>
        /// <para>Mean Center Layer</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Mean Center Layer")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_mean_center_layer { get; set; }


        /// <summary>
        /// <para>Median Center Layer</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Median Center Layer")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_median_center_layer { get; set; }


        /// <summary>
        /// <para>Ellipse Layer</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Ellipse Layer")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_ellipse_layer { get; set; }


        /// <summary>
        /// <para>Data Store</para>
        /// <para><xdoc>
        ///   <para>Specifies the ArcGIS Data Store where the output will be saved. The default is Spatiotemporal big data store. All results stored in a spatiotemporal big data store will be stored in WGS84. Results stored in a relational data store will maintain their coordinate system.</para>
        ///   <bulletList>
        ///     <bullet_item>Spatiotemporal big data store—Output will be stored in a spatiotemporal big data store. This is the default.</bullet_item><para/>
        ///     <bullet_item>Relational data store—Output will be stored in a relational data store.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将保存输出的 ArcGIS Data Store。默认值为 Spatiotemporal 大数据存储。存储在时空大数据存储中的所有结果都将存储在 WGS84 中。存储在关系数据存储中的结果将保留其坐标系。</para>
        ///   <bulletList>
        ///     <bullet_item>时空大数据存储 - 输出将存储在时空大数据存储中。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>关系数据存储 - 输出将存储在关系数据存储中。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Data Store")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _data_store_value _data_store { get; set; } = _data_store_value._SPATIOTEMPORAL_DATA_STORE;

        public enum _data_store_value
        {
            /// <summary>
            /// <para>Spatiotemporal big data store</para>
            /// <para>Spatiotemporal big data store—Output will be stored in a spatiotemporal big data store. This is the default.</para>
            /// <para>时空大数据存储 - 输出将存储在时空大数据存储中。这是默认设置。</para>
            /// </summary>
            [Description("Spatiotemporal big data store")]
            [GPEnumValue("SPATIOTEMPORAL_DATA_STORE")]
            _SPATIOTEMPORAL_DATA_STORE,

            /// <summary>
            /// <para>Relational data store</para>
            /// <para>Relational data store—Output will be stored in a relational data store.</para>
            /// <para>关系数据存储 - 输出将存储在关系数据存储中。</para>
            /// </summary>
            [Description("Relational data store")]
            [GPEnumValue("RELATIONAL_DATA_STORE")]
            _RELATIONAL_DATA_STORE,

        }

        public SummarizeCenterAndDispersion SetEnv(object extent = null, object outputCoordinateSystem = null, object workspace = null)
        {
            base.SetEnv(extent: extent, outputCoordinateSystem: outputCoordinateSystem, workspace: workspace);
            return this;
        }

    }

}